-- GENERATED SPELL FOR [Carnage] --


function spell0_31271(pUnit, Event) --@Smash,n/a--
pUnit:FullCastSpellOnTarget(61070,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_31271', 597, 1)
end

function spell1_31271(pUnit, Event) --@War Stomp,Self--
pUnit:FullCastSpellOnTarget(61065,pUnit)
pUnit:RegisterEvent('Sorts_31271', 2000, 1)
end

function Sorts_31271(pUnit, Event)
local choix_sorts_31271 = math.random(0, 1)
if choix_sorts_31271 == 0 then
pUnit:RegisterEvent('spell0_31271', 1, 1)
end
if choix_sorts_31271 == 1 then
pUnit:RegisterEvent('spell1_31271', 1, 1)
end
end

function mob31271_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_31271', math.random(1500, 3000), 1)
end

function mob31271_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob31271_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob31271_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(31271, 1, 'mob31271_Action')
RegisterUnitEvent(31271, 2, 'mob31271_Leave')
RegisterUnitEvent(31271, 3, 'mob31271_Kill')
RegisterUnitEvent(31271, 4, 'mob31271_Die')
